package com.hxbd.gxsec_data.dao;

import com.alibaba.fastjson.JSONObject;
import com.hxbd.gxsec_data.pojo.ImgDO;
import com.hxbd.gxsec_data.pojo.NewsDO;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;
import java.util.Map;

@Repository
public interface NewsDao {

    public boolean addNewsData(@Param("map")Map<String,Object> map);

    public boolean updateNewsData(@Param("map")Map<String,Object> map);

    public boolean batchNewsData(@Param("newsId")String id);

    public List<JSONObject> selectNewsDatasByParam();

    public boolean uploadImg(@Param("img") ImgDO imgDO);

    public boolean batchUploadImg(@Param("url") String url);

    List<JSONObject> getNewsByname(@Param(value = "name") String name);
}